package org.flow.basic.thread.comfuture;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.util.concurrent.CompletableFuture;

/**
 * @author xl-9527
 * @since 2024/9/1
 **/
public class CompFutureDemo {

    private final Logger log = LoggerFactory.getLogger(CompFutureDemo.class);

    public void asyncCompletableFuture() {
        final CompletableFuture<Void> async = CompletableFuture.runAsync(() -> {
            log.info("i am is running");
        });
        async.join();
    }


}
